<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<!--头碎片-->
<head th:replace="fragment/Headfragment::Headfragment">
</head>

<body>
<div class="container-scroller">
    <!-- 页头碎片 -->
    <nav th:replace="fragment/PageHeadfragmeng::PageHeadfragment"></nav>
    <!-- partial -->
    <div class="container-fluid page-body-wrapper">
        <!-- partial:../../partials/_sidebar.html -->
        <nav th:replace="fragment/PageSidebarfragment::PageSidebarfragment"></nav>
        <!-- partial -->
        <div class="main-panel">
            <div class="page-header">
                <h3 class="page-title">
              <span class="page-title-icon bg-gradient-primary text-white mr-2">
                <i class="mdi mdi-home"></i>
              </span>
                    主页
                </h3>
                <nav aria-label="breadcrumb">
                    <ul class="breadcrumb">
                        <li class="breadcrumb-item active" aria-current="page">
                            <span></span>Overview
                            <i class="mdi mdi-alert-circle-outline icon-sm text-primary align-middle"></i>
                        </li>
                    </ul>
                </nav>
            </div>
            <div class="col-12 grid-margin stretch-card">
                <div class="card">
                    <div class="card-body">
                        <h4 class="card-title">客服信息表</h4>
                        <form action="/customerService/search" method="post">
                            <div class="form-group">

                                <div class="input-group">
                                    <input type="text" placeholder="ID" class="form-control" name="id"
                                           autocomplete="off">
                                    <button type="submit" class="btn btn-sm btn-gradient-primary">搜索</button>
                                </div>

                            </div>
                        </form>

                        <div class="table-responsive">
                            <table class="table">
                                <thead>
                                <tr>
                                    <th width="10%">ID</th>
                                    <th width="20%">名称</th>
                                    <th width="20%">状态</th>
                                    <th width="20%">上线时间</th>
                                    <th width="10%">对话数</th>
                                </tr>
                                </thead>
                                <tbody>
                                <tr th:each="cs:${list}">
                                    <td th:text="${cs.getCustomerserviceid()}">1</td>
                                    <td th:text="${cs.getRealname()}"><span class="badge badge-primary">1</span></td>
                                    <td th:text="${cs.getState()}">离线</td>
                                    <td class="color-primary" th:text="${cs.getOnlinetimebegin().getYear()+'-'+cs.getOnlinetimebegin().getMonthValue()+'-'+cs.getOnlinetimebegin().getDayOfMonth()+'  '
                                                          +cs.getOnlinetimebegin().getHour()+':'+cs.getOnlinetimebegin().getMinute()+':'+cs.getOnlinetimebegin().getSecond()}">
                                    </td>
                                    <td th:text="${cs.getSessioncount()}">10</td>
                                </tr>
                                </tbody>
                            </table>
                            <div align="center">
                                <a th:href="@{customerService/CustomerService(current=1,size=8)}"><span th:text="首页"
                                                                                                        style="color: black"></span></a>
                                <a th:href="@{customerService/CustomerService(current=${i},size=8)}"
                                   th:each="i : ${#numbers.sequence(1,pagesCount)}"><span th:text="${i}"
                                                                                          style="color: black; height: 16px;width: 16px;text-align: center;vertical-align: middle;padding-left: 5px;padding-right: 5px;margin-left: 10px;margin-right: 10px"></span></a>
                                <a th:href="@{customerService/CustomerService(current=${pagesCount},size=8)}"><span
                                        th:text="尾页" style="color: black"></span></a>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <!-- main-panel ends -->
    </div>
    <!-- page-body-wrapper ends -->
</div>
<!-- container-scroller -->
<!-- plugins:js -->
<script src="vendors/js/vendor.bundle.base.js"></script>
<script src="vendors/js/vendor.bundle.addons.js"></script>
<!-- endinject -->
<!-- Plugin js for this page-->
<!-- End plugin js for this page-->
<!-- inject:js -->
<script src="js/off-canvas.js"></script>
<script src="js/misc.js"></script>
<!-- endinject -->
<!-- Custom js for this page-->
<!-- End custom js for this page-->
</body>

</html>
